1. Field of the Invention
The present invention relates to electronic circuits, and more specifically to a method and circuit for determining the signal amplitude at the input of an analog-to-digital converter.
2. Description of Related Art
Today, electronic communication generally involves both analog signal processing and digital signal processing. Typically, an analog-to-digital (A/D) converter converts an initial analog signal into a digital signal for processing and transmittal, and then a digital-to-analog (D/A) converter converts the digital signal back into an analog signal for playback. A portion of an electronic communication circuit is shown in FIG. 1.
An analog input signal is first supplied to a variable gain amplifier 10 that performs gain correction and then to a continuous time filter 12 (e.g., a low-pass filter) that filters out unwanted components. An A/D converter 14 converts the output of the filter 12 into a digital signal, and then various processing is performed by a digital signal processor 16 to produce a digital output signal for transmission or playback. In order to minimize distortion and maximize the signal-to-noise ratio, the digital signal processor 16 calculates the optimum amplitude for the signal that is input to the A/D converter 14 and outputs a corresponding correction signal ERR to the variable gain amplifier 10.
However, due to the latency of such a feedback loop, the correction signal ERR must have a low bandwidth relative to the analog input signal. As a result, at the start of a signal burst or when there is a major change in the analog signal, the A/D converter must produce many digital samples before the automatic gain control feedback loop can modify the amplitude of the analog signal to the proper level. This is known as acquire-and-track because the automatic gain control feedback loop must first acquire the gain level needed to produce the desired amplitude and then track minor variations in the amplitude of the analog input signal. During the long time required to acquire the desired amplitude, the digital signal output by the A/D converter can be of poor quality or even unusable.
In view of these drawbacks, it is an object of the present invention to overcome the above-mentioned drawbacks and to provide a method for quickly determining the amplitude of an input signal.
Another object of the present invention is to provide an electronic communication circuit that can quickly adjust the amplitude of an analog input signal to a desired level.
One embodiment of the present invention provides a method for determining the actual amplitude of a signal relative to a predetermined amplitude. According to the method, two samples of the signal are squared to produce two squared samples, and the sum of the two squared samples minus the square of the predetermined amplitude is calculated to produce a difference of squares. A shift operation is performed on the difference of squares to determine a difference between the actual amplitude and the predetermined amplitude. In a preferred embodiment, two consecutive samples of the signal are taken at four times the frequency of the signal.
Another embodiment of the present invention provides a circuit device that includes an A/D converter, a variable gain amplifier, and a feedback loop. The A/D converter converts an analog signal into a digital signal, and the variable gain amplifier adjusts the amplitude of the analog signal. The feedback loop controls the variable gain amplifier based on a difference between the amplitude of the analog signal and a predetermined amplitude. Further, the feedback loop calculates the difference by squaring two samples of the digital signal, summing the two squared samples and subtracting the square of the predetermined amplitude to produce a result, and shifting the result. In one preferred embodiment, the feedback loop includes an arithmetic logic unit.
Other objects, features, and advantages of the present invention will become apparent from the following detailed description. It should be understood, however, that the detailed description and specific examples, while indicating preferred embodiments of the present invention, are given by way of illustration only and various modifications may naturally be performed without deviating from the present invention.